import sqlite3


def readTileFromMBT(path, level, row, column):
    conn = sqlite3.connect(path, check_same_thread=False)
    cur = conn.cursor()

    img = cur.execute(
        'select tile_data from tiles where zoom_level = ? and tile_row = ? and tile_column = ?',
        (level, row, column)).fetchall()

    cur.close()
    conn.close()

    return img